package com.ruiyian.bridge.project.enums;



public enum WarnDgreeEnum {

	YELLOW("1","黄色预警"),
	ORANGE("2","橙色预警"),
	RED("3","红色预警");

	private String warnDgree;

	private String desc;

	public static WarnDgreeEnum getWarnDegreeByDegree(String degree) {
		for (WarnDgreeEnum warn : values()) {
			if (warn.getWarnDgree().equals(degree)) {
				return warn;
			}
		}
		return WarnDgreeEnum.YELLOW;
	}

	private WarnDgreeEnum(String warnDgree, String desc) {
		this.warnDgree = warnDgree;
		this.desc = desc;
	}

	public String getWarnDgree() {
		return warnDgree;
	}

	public void setWarnDgree(String warnDgree) {
		this.warnDgree = warnDgree;
	}

	public String getDesc() {
		return desc;
	}

	public void setDesc(String desc) {
		this.desc = desc;
	}



}
